package com.ruoyi.system.domain;

import java.math.BigDecimal;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.system.api.domain.SysUser;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.core.annotation.Excel;
import com.ruoyi.common.core.web.domain.BaseEntity;

/**
 * 商品对象 order_bill
 *
 * @author ruoyi
 * @date 2021-11-24
 */
public class SysCommodity extends BaseEntity {
    private static final long serialVersionUID = 1L;

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }

    /**
     * 主键ID
     */
    private Long id;

    /**
     * 账单编码
     */
    @Excel(name = "账单编码")
    private Long commoditycode;

    /**
     * 商品名称
     */
    @Excel(name = "商品名称")
    private String productname;

    /**
     * 商品描述
     */
    @Excel(name = "商品描述")
    private String productdesc;

    /**
     * 商品描述
     */
    @Excel(name = "商品图片")
    private String productimages;

    /**
     * 商品单位
     */
    @Excel(name = "商品单位")
    private String productunit;

    /**
     * 商品数量
     */
    @Excel(name = "商品数量")
    private BigDecimal productcount;

    /**
     * 商品单价
     */
    @Excel(name = "商品价格")
    private Double productprice;

    /**
     * 创建者（userId）
     */
    @Excel(name = "创建者", readConverterExp = "u=serId")
    private Long createdby;

    @Excel(name = "创建者信息", readConverterExp = "u=serId")
    private SysUser createdSysUser;
    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date creationdate;

    /**
     * 更新者（userId）
     */
    @Excel(name = "更新者", readConverterExp = "u=serId")
    private Long modifyby;

    @Excel(name = "更新者信息", readConverterExp = "u=serId")
    private SysUser modifySysUser;
    /**
     * 更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date modifydate;

    public Double getProductprice() {
        return productprice;
    }

    public void setProductprice(Double productprice) {
        this.productprice = productprice;
    }

    public String getProductimages() {
        return productimages;
    }

    public void setProductimages(String productimages) {
        this.productimages = productimages;
    }

    public SysUser getCreatedSysUser() {
        return createdSysUser;
    }

    public void setCreatedSysUser(SysUser createdSysUser) {
        this.createdSysUser = createdSysUser;
    }

    public SysUser getModifySysUser() {
        return modifySysUser;
    }

    public void setModifySysUser(SysUser modifySysUser) {
        this.modifySysUser = modifySysUser;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public Long getCommoditycode() {
        return commoditycode;
    }

    public void setCommoditycode(Long commoditycode) {
        this.commoditycode = commoditycode;
    }

    public void setProductname(String productname) {
        this.productname = productname;
    }

    public String getProductname() {
        return productname;
    }

    public void setProductdesc(String productdesc) {
        this.productdesc = productdesc;
    }

    public String getProductdesc() {
        return productdesc;
    }

    public void setProductunit(String productunit) {
        this.productunit = productunit;
    }

    public String getProductunit() {
        return productunit;
    }

    public void setProductcount(BigDecimal productcount) {
        this.productcount = productcount;
    }

    public BigDecimal getProductcount() {
        return productcount;
    }


    public void setCreatedby(Long createdby) {
        this.createdby = createdby;
    }

    public Long getCreatedby() {
        return createdby;
    }

    public void setCreationdate(Date creationdate) {
        this.creationdate = creationdate;
    }

    public Date getCreationdate() {
        return creationdate;
    }

    public void setModifyby(Long modifyby) {
        this.modifyby = modifyby;
    }

    public Long getModifyby() {
        return modifyby;
    }

    public void setModifydate(Date modifydate) {
        this.modifydate = modifydate;
    }

    public Date getModifydate() {
        return modifydate;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("commoditycode", getCommoditycode())
                .append("productname", getProductname())
                .append("productdesc", getProductdesc())
                .append("productunit", getProductunit())
                .append("productcount", getProductcount())
                .append("createdby", getCreatedby())
                .append("creationdate", getCreationdate())
                .append("modifyby", getModifyby())
                .append("modifydate", getModifydate())
                .append("productprice", getProductprice())
                .toString();
    }
}
